#ifndef VPDECODEVIDEOTHREAD_H
#define VPDECODEVIDEOTHREAD_H

#include <VpFrameQueue.h>
#include <VpPacketQueue.h>
extern "C"
{
#include <libavcodec/avcodec.h>

}

#define MAX_VIDEO_FRAME_NUM 3
class VpDecodeVideoThread
{
private:
    bool               m_stop;
    mutex              m_mutex;
    condition_variable m_cond;
public:
                VpDecodeVideoThread();
    bool        start              (AVCodecContext *codec_ctx, VpPacketQueue *video_pkt_queue, VpFrameQueue *video_fme_queue);
    void        stop               ();
    static void work               (VpDecodeVideoThread* vp_decode_video_th, AVCodecContext *codec_ctx, VpPacketQueue *video_pkt_queue, VpFrameQueue *video_fme_queue);
};

#endif // VPDECODEVIDEOTHREAD_H
